package com.net.core.core;

public class YXException extends RuntimeException {
    private static final long serialVersionUID = 1L;
    Exception e;

    public YXException(String message) {
        super(message);
    }

    public YXException(String message, Exception e) {
        super(message);
        this.e = e;
    }

    public Exception getException() {
        if (this.e == null) {
            this.e = this;
        }

        return this.e;
    }

    public YXException(Throwable cause) {
        super(cause);
    }

    public YXException(String message, Throwable cause) {
        super(message, cause);
    }
}

